import request from './request.js'
import base from './base.js'

export default {
	wx_login(params) {//登录
 		return request({
			base: base.apiUrl,//使用base中的哪个域名地址
			url: '/user/wxLogin',//请求地址后缀
			method: 'post',//请求方法 get,post,delete没有data,
			data: params,//请求参数
			isLoding: true,//时候显示加载框 true false
		})
	},
	get_distance(params) {//门店列表
		return request({
			base: base.apiUrl,
			url: '/store/getDistance',
			method: 'post',
			data: params,
			isLoding: false,
		})
	},
	store_list(params) {//门店列表
		return request({
			base: base.apiUrl,
			url: '/store/getList',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	store_saveUsetStore(params) {//绑定店铺
		return request({
			base: base.apiUrl,
			url: '/store/saveUsetStore',
			method: 'post',
			data: params
		})
	},
	store_getStore(params) {//门店详情
		return request({
			base: base.apiUrl,
			url: '/store/getStore',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	goods_homeGoods(params) {//首页商品列表
		return request({
			base: base.apiUrl,
			url: '/goods/homeGoods',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	goods_getContent(params) {//商品详情 
		return request({
			base: base.apiUrl,
			url: '/goods/getContent',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	ShopCar_addGood(params) {//商品添加到购物车
		return request({
			base: base.apiUrl,
			url: '/ShopCar/addGood',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	UserComment_commentList(params) {//评论列表
		return request({
			base: base.apiUrl,
			url: '/UserComment/commentList',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	Order_submit(params) {//提交订单
		return request({
			base: base.apiUrl,
			url: '/Order/submit',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	store_storeBasic(params) {//店铺基本数据
		return request({
			base: base.apiUrl,
			url: '/store/storeBasic',
			method: 'post',
			data: params,
			isLoding: false,
		})
	},
	Service_serviceList() {//服务列表
		return request({
			base: base.apiUrl,
			url: '/Service/serviceList',
			method: 'post',
			isLoding: true,
		})
	},
	Service_technicianList(params) {//服务列表
		return request({
			base: base.apiUrl,
			url: '/Service/technicianList',
			method: 'post',
			data: params,
			isLoding: true,
			isLoding: true,
		})
	},
	Service_timeList(params) {//服务时间选择列表 
		return request({
			base: base.apiUrl,
			url: '/Service/timeList',
			method: 'post',
			data: params,
		})
	},
	Service_serviceConfirm(params) {//服务订单确认页 
		return request({
			base: base.apiUrl,
			url: '/Service/serviceConfirm',
			method: 'post',
			data: params,			
			isLoding: true,
		})
	},
	Service_submit(params) {//提交服务  
		return request({
			base: base.apiUrl,
			url: '/Service/submit',
			method: 'post',
			data: params,			
			isLoding: true,
		})
	},
	Goods_activeImage(params) {//首页图片列表   
		return request({
			base: base.apiUrl,
			url: '/Goods/activeImage',
			method: 'post',
			data: params
		})
	},
	User_savePid(params) {//绑定用户上级   
	console.log(params)
		return request({
			base: base.apiUrl,
			// url: '/User/savePid',
			url: '/User/addPreparePid',
			method: 'post',
			data: params			
		})
	},
	Coupon_couponCount(params) {//优惠券详情   
		return request({
			base: base.apiUrl,
			url: '/Coupon/couponCount',
			method: 'post',
			data: params			
		})
	},
	Coupon_saveUserCoupon(params) {//领取优惠券   
		return request({
			base: base.apiUrl,
			url: '/Coupon/saveUserCoupon',
			method: 'post',
			data: params			
		})
	},
	Goods_active(params) {//首页活动列表
		return request({
			base: base.apiUrl,
			url: '/Goods/active',
			method: 'post',
			data: params
		})
	},
	Service_technician(params) {//技师详情 
		return request({
			base: base.apiUrl,
			url: '/Service/technician',
			method: 'post',
			data: params,			
			isLoding: true,		
		})
	},
	Service_technicianComment(params) {//技师评论接口
		return request({
			base: base.apiUrl,
			url: '/Service/technicianComment',
			method: 'post',
			data: params,			
			isLoding: true,		
		})
	},
	Goods_inStock(params) {//商品是否有库存
		return request({
			base: base.apiUrl,
			url: '/Goods/inStock_V1',
			method: 'post',
			data: params,			
		})
	},
	
	user_focusOn(params) {//商品是否有库存
		return request({
			base: base.apiUrl,
			url: '/User/getFocusOn',
			method: 'get',
			data: params,
			isLoding: false,
		})
	},
	Service_Service(params) {//服务是否可以下单
		return request({
			base: base.apiUrl,
			url: '/Service/isService',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	Goods_recommendGoods(params) {//推荐商品
		return request({
			base: base.apiUrl,
			url: '/Goods/recommendGoods',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	Agent_upContent(params) {//代理升级详情 
		return request({
			base: base.apiUrl,
			url: '/Agent/upContent',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	Agent_payUpgrade(params) {//购买升级等级 
		return request({
			base: base.apiUrl,
			url: '/Agent/payUpgrade',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	Order_mybalance(params) {//查询余额，货款 
		return request({
			base: base.apiUrl,
			url: '/Order/mybalance',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	User_getUser(params) {//查询可否货款支付	
		return request({
			base: base.apiUrl,
			url: '/User/getUser',
			method: 'post',
			data: params,
			isLoding: true,
		})
	},
	
}